﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace AiXiu.IService
{
    /// <summary>
    /// 点赞业务逻辑接口
    /// </summary>
    public interface ILikeService
    {
        /// <summary>
        /// 点赞计数
        /// </summary>
        /// <param name="videoId">视频Id</param>
        /// <returns></returns>
        long Count(string videoId);

        /// <summary>
        /// 是否已点赞
        /// </summary>
        /// <param name="videoId">视频Id</param>
        /// <param name="userId">用户Id</param>
        /// <returns></returns>
        bool IsLike(string videoId, int userId);

        /// <summary>
        /// 添加点赞
        /// </summary>
        /// <param name="videoId">视频Id</param>
        /// <param name="userId">用户Id</param>
        /// <returns></returns>
        bool AddLike(string videoId, int userId);

        /// <summary>
        /// 移除点赞
        /// </summary>
        /// <param name="videoId">视频Id</param>
        /// <param name="userId">用户Id</param>
        /// <returns></returns>
        bool RemoveLike(string videoId, int userId);
    }
}
